package com.yanqu.road.entity.systemgroup.newmonopolymarket.office;

import com.yanqu.road.entity.DataObject;
import com.yanqu.road.entity.DataStatus;
import com.yanqu.road.entity.FieldTypeAnnotation;

@FieldTypeAnnotation(tableName = "t_c_new_monopoly_market_office_finish")
public class NewMonopolyMarketOfficeFinishData extends DataObject {
    @FieldTypeAnnotation(update = true)
    private long id;

    @FieldTypeAnnotation(desc = "每周", select = true)
    private int weekId;

    @FieldTypeAnnotation(desc = "分组id", select = true)
    private long groupId;

    @FieldTypeAnnotation(desc = "玩家")
    private long userId;

    @FieldTypeAnnotation(desc = "据点id")
    private int posIndex;

    @FieldTypeAnnotation(desc = "被抢位置的等级")
    private byte level;

    @FieldTypeAnnotation(desc = "被抢位置的编号")
    private int no;

    @FieldTypeAnnotation(desc = "抢夺玩家名称")
    private String robName;

    @FieldTypeAnnotation(desc = "是否已经同步")
    private boolean isSyn;

    @FieldTypeAnnotation(desc = "完成类型：0：被抢；1：22点结算")
    private int finishType;

    @FieldTypeAnnotation(desc = "被抢时间 奖励保留30天，过期不加载)")
    private int time;

    public long getId() {
        return id;
    }
    public void setId(long id) {
        if (this.id != id) {
            this.id = id;
            setOp(DataStatus.Update);
        }
    }

    public int getWeekId() {
        return weekId;
    }

    public void setWeekId(int weekId) {
        if(this.weekId != weekId) {
            this.weekId = weekId;
            setUpdateOption();
        }
    }

    public long getGroupId() {
        return groupId;
    }

    public void setGroupId(long groupId) {
        if(this.groupId != groupId) {
            this.groupId = groupId;
            setUpdateOption();
        }
    }

    public long getUserId() {
        return userId;
    }
    public void setUserId(long userId) {
        if (this.userId != userId) {
            this.userId = userId;
            setOp(DataStatus.Update);
        }
    }

    public int getPosIndex() {
        return posIndex;
    }
    public void setPosIndex(int posIndex) {
        if (this.posIndex != posIndex) {
            this.posIndex = posIndex;
            setOp(DataStatus.Update);
        }
    }

    public byte getLevel() {
        return level;
    }
    public void setLevel(byte level) {
        if (this.level != level) {
            this.level = level;
            setOp(DataStatus.Update);
        }
    }

    public int getNo() {
        return no;
    }
    public void setNo(int no) {
        if (this.no != no) {
            this.no = no;
            setOp(DataStatus.Update);
        }
    }

    public String getRobName() {
        return robName;
    }
    public void setRobName(String robName) {
        if (robName == null){
            return;
        }
        if (this.robName == null || !this.robName.equals(robName)) {
            this.robName = robName;
            setOp(DataStatus.Update);
        }
    }

    public boolean getIsSyn() {
        return isSyn;
    }
    public void setIsSyn(boolean isSyn) {
        if (this.isSyn != isSyn) {
            this.isSyn = isSyn;
            setOp(DataStatus.Update);
        }
    }

    public int getFinishType() {
        return finishType;
    }

    public void setFinishType(int finishType) {
        if(this.finishType != finishType) {
            this.finishType = finishType;
            setUpdateOption();
        }
    }

    public int getTime() {
        return time;
    }
    public void setTime(int time) {
        if (this.time != time) {
            this.time = time;
            setOp(DataStatus.Update);
        }
    }
}
